Integrand size = 38, antiderivative size = 239 \[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\frac {(A+B) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-4-p}}{f g (7+p)}+\frac {(3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-3-p}}{c f g (5+p) (7+p)}+\frac {2 (3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-2-p}}{c^2 f g (3+p) (5+p) (7+p)}+\frac {2 (3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-1-p}}{c^3 f g (1+p) (3+p) (5+p) (7+p)} \]
[Out]
Time = 0.32 (sec) , antiderivative size = 239, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.079, Rules used = {2938, 2751, 2750} \[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\frac {2 (3 A-B (p+4)) (c-c \sin (e+f x))^{-p-1} (g \cos (e+f x))^{p+1}}{c^3 f g (p+1) (p+3) (p+5) (p+7)}+\frac {2 (3 A-B (p+4)) (c-c \sin (e+f x))^{-p-2} (g \cos (e+f x))^{p+1}}{c^2 f g (p+3) (p+5) (p+7)}+\frac {(A+B) (c-c \sin (e+f x))^{-p-4} (g \cos (e+f x))^{p+1}}{f g (p+7)}+\frac {(3 A-B (p+4)) (c-c \sin (e+f x))^{-p-3} (g \cos (e+f x))^{p+1}}{c f g (p+5) (p+7)} \]
[In]
[Out]
Rule 2750
Rule 2751
Rule 2938
Rubi steps \begin{align*} \text {integral}& = \frac {(A+B) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-4-p}}{f g (7+p)}+\frac {(3 A-B (4+p)) \int (g \cos (e+f x))^p (c-c \sin (e+f x))^{-3-p} \, dx}{c (7+p)} \\ & = \frac {(A+B) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-4-p}}{f g (7+p)}+\frac {(3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-3-p}}{c f g (5+p) (7+p)}+\frac {(2 (3 A-B (4+p))) \int (g \cos (e+f x))^p (c-c \sin (e+f x))^{-2-p} \, dx}{c^2 (5+p) (7+p)} \\ & = \frac {(A+B) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-4-p}}{f g (7+p)}+\frac {(3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-3-p}}{c f g (5+p) (7+p)}+\frac {2 (3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-2-p}}{c^2 f g (3+p) (5+p) (7+p)}+\frac {(2 (3 A-B (4+p))) \int (g \cos (e+f x))^p (c-c \sin (e+f x))^{-1-p} \, dx}{c^3 (3+p) (5+p) (7+p)} \\ & = \frac {(A+B) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-4-p}}{f g (7+p)}+\frac {(3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-3-p}}{c f g (5+p) (7+p)}+\frac {2 (3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-2-p}}{c^2 f g (3+p) (5+p) (7+p)}+\frac {2 (3 A-B (4+p)) (g \cos (e+f x))^{1+p} (c-c \sin (e+f x))^{-1-p}}{c^3 f g (1+p) (3+p) (5+p) (7+p)} \\ \end{align*}
Time = 0.37 (sec) , antiderivative size = 160, normalized size of antiderivative = 0.67 \[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\frac {\cos (e+f x) (g \cos (e+f x))^p (c-c \sin (e+f x))^{-p} \left (-B \left (13+8 p+p^2\right )+A \left (36+41 p+12 p^2+p^3\right )+\left (13+8 p+p^2\right ) (-3 A+B (4+p)) \sin (e+f x)-2 (4+p) (-3 A+B (4+p)) \sin ^2(e+f x)+(-6 A+2 B (4+p)) \sin ^3(e+f x)\right )}{c^4 f (1+p) (3+p) (5+p) (7+p) (-1+\sin (e+f x))^4} \]
[In]
[Out]
\[\int \left (g \cos \left (f x +e \right )\right )^{p} \left (A +B \sin \left (f x +e \right )\right ) \left (c -c \sin \left (f x +e \right )\right )^{-4-p}d x\]
[In]
[Out]
none
Time = 0.30 (sec) , antiderivative size = 197, normalized size of antiderivative = 0.82 \[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\frac {{\left (2 \, {\left (B p^{2} - {\left (3 \, A - 8 \, B\right )} p - 12 \, A + 16 \, B\right )} \cos \left (f x + e\right )^{3} + {\left (A p^{3} + 3 \, {\left (4 \, A - B\right )} p^{2} + {\left (47 \, A - 24 \, B\right )} p + 60 \, A - 45 \, B\right )} \cos \left (f x + e\right ) - {\left (2 \, {\left (B p - 3 \, A + 4 \, B\right )} \cos \left (f x + e\right )^{3} - {\left (B p^{3} - 3 \, {\left (A - 4 \, B\right )} p^{2} - {\left (24 \, A - 47 \, B\right )} p - 45 \, A + 60 \, B\right )} \cos \left (f x + e\right )\right )} \sin \left (f x + e\right )\right )} \left (g \cos \left (f x + e\right )\right )^{p} {\left (-c \sin \left (f x + e\right ) + c\right )}^{-p - 4}}{f p^{4} + 16 \, f p^{3} + 86 \, f p^{2} + 176 \, f p + 105 \, f} \]
[In]
[Out]
\[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\int \left (g \cos {\left (e + f x \right )}\right )^{p} \left (- c \left (\sin {\left (e + f x \right )} - 1\right )\right )^{- p - 4} \left (A + B \sin {\left (e + f x \right )}\right )\, dx \]
[In]
[Out]
\[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\int { {\left (B \sin \left (f x + e\right ) + A\right )} \left (g \cos \left (f x + e\right )\right )^{p} {\left (-c \sin \left (f x + e\right ) + c\right )}^{-p - 4} \,d x } \]
[In]
[Out]
\[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\int { {\left (B \sin \left (f x + e\right ) + A\right )} \left (g \cos \left (f x + e\right )\right )^{p} {\left (-c \sin \left (f x + e\right ) + c\right )}^{-p - 4} \,d x } \]
[In]
[Out]
Time = 19.44 (sec) , antiderivative size = 441, normalized size of antiderivative = 1.85 \[ \int (g \cos (e+f x))^p (A+B \sin (e+f x)) (c-c \sin (e+f x))^{-4-p} \, dx=\frac {\cos \left (e+f\,x\right )\,{\left (g\,\left (\frac {{\mathrm {e}}^{-e\,1{}\mathrm {i}-f\,x\,1{}\mathrm {i}}}{2}+\frac {{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}}{2}\right )\right )}^p\,\left (A\,168{}\mathrm {i}-B\,84{}\mathrm {i}+A\,p\,170{}\mathrm {i}-B\,p\,48{}\mathrm {i}+A\,p^2\,48{}\mathrm {i}+A\,p^3\,4{}\mathrm {i}-B\,p^2\,6{}\mathrm {i}\right )}{4\,f\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{p+4}\,\left (p^4\,1{}\mathrm {i}+p^3\,16{}\mathrm {i}+p^2\,86{}\mathrm {i}+p\,176{}\mathrm {i}+105{}\mathrm {i}\right )}-\frac {\sin \left (4\,e+4\,f\,x\right )\,{\left (g\,\left (\frac {{\mathrm {e}}^{-e\,1{}\mathrm {i}-f\,x\,1{}\mathrm {i}}}{2}+\frac {{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}}{2}\right )\right )}^p\,\left (4\,B-3\,A+B\,p\right )\,1{}\mathrm {i}}{4\,f\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{p+4}\,\left (p^4\,1{}\mathrm {i}+p^3\,16{}\mathrm {i}+p^2\,86{}\mathrm {i}+p\,176{}\mathrm {i}+105{}\mathrm {i}\right )}+\frac {\cos \left (3\,e+3\,f\,x\right )\,{\left (g\,\left (\frac {{\mathrm {e}}^{-e\,1{}\mathrm {i}-f\,x\,1{}\mathrm {i}}}{2}+\frac {{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}}{2}\right )\right )}^p\,\left (p+4\right )\,\left (-A\,3{}\mathrm {i}+B\,4{}\mathrm {i}+B\,p\,1{}\mathrm {i}\right )}{2\,f\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{p+4}\,\left (p^4\,1{}\mathrm {i}+p^3\,16{}\mathrm {i}+p^2\,86{}\mathrm {i}+p\,176{}\mathrm {i}+105{}\mathrm {i}\right )}+\frac {\sin \left (2\,e+2\,f\,x\right )\,{\left (g\,\left (\frac {{\mathrm {e}}^{-e\,1{}\mathrm {i}-f\,x\,1{}\mathrm {i}}}{2}+\frac {{\mathrm {e}}^{e\,1{}\mathrm {i}+f\,x\,1{}\mathrm {i}}}{2}\right )\right )}^p\,\left (4\,B-3\,A+B\,p\right )\,\left (p^2+8\,p+14\right )\,1{}\mathrm {i}}{2\,f\,{\left (c-c\,\sin \left (e+f\,x\right )\right )}^{p+4}\,\left (p^4\,1{}\mathrm {i}+p^3\,16{}\mathrm {i}+p^2\,86{}\mathrm {i}+p\,176{}\mathrm {i}+105{}\mathrm {i}\right )} \]
[In]
[Out]